package com.jojo.controller;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
//@RequestMapping("/hello")
public class HelloController {
    @RequestMapping("/hi")
    public String hello(Model model){
//        封装数据
        model.addAttribute("msg","你好，springmvc注解！");
        return "hello";//会被视图解析器处理
    }
}
